<?php
include_once('../includes/definer.php');
include_once(INC.'php/bootstrap.php');
$categoria = Doctrine::getTable('categoria')->find($_POST['id']);
$response = 'error';
if (!$categoria->hasPublicaciones()) {
    $categoria->delete();
    $response = 'success';
}
echo($response);
?>
